package com.yz.jdd.webview.net;

import com.google.gson.JsonObject;
import com.yz.jdd.base.entity.Response_Base;

import java.util.Map;

import retrofit2.http.Body;
import retrofit2.http.GET;
import retrofit2.http.Header;
import retrofit2.http.HeaderMap;
import retrofit2.http.Headers;
import retrofit2.http.POST;
import retrofit2.http.Path;
import retrofit2.http.QueryMap;
import retrofit2.http.Url;
import rx.Observable;

/**
 * 项目名称：Maneki
 * 创建人：zx
 * 创建时间：2017/1/14-上午10:54
 */

public interface H5RequestInterface {
    /**
     * h5请求
     *
     * @return
     */
//    @POST("{url}")
//    public Observable<Response_Base> h5SendPostMsg(@Path String url, @Body JsonObject options);

    //h5通用post请求
    @POST
    public Observable<Response_Base> h5RequestPost(@HeaderMap Map<String, Object> headers, @Url String url, @Body JsonObject options);

    //h5通用get请求
    @GET
    public Observable<Response_Base> h5RequestGet(@HeaderMap Map<String, Object> headers, @Url String url, @QueryMap Map<String, Object> options);

    //退出登录
    @GET("app/setting/logout.do")
    public Observable<Response_Base> h5LogoutGet();


}
